<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------

use think\Route;


// 首页
Route::rule('admin','admin/index/index');
Route::rule('welcome','admin/index/welcome');

// 登录
Route::rule('admin/login','admin/login/login');
Route::rule('admin/logout','admin/login/logout');

// 管理员
Route::rule('adminAdd','admin/admin/adminAdd');
Route::rule('adminList','admin/admin/adminList');
Route::rule('adminEdit','admin/admin/adminEdit');
Route::rule('adminDel','admin/admin/adminDel');
Route::rule('adminActive','admin/admin/adminActive');
Route::rule('adminShow','admin/admin/adminShow');

// 用户管理
Route::rule('usersAdd','admin/user/usersAdd');
Route::rule('usersList','admin/user/usersList');
Route::rule('usersEdit','admin/user/usersEdit');
Route::rule('usersDel','admin/user/usersDel');

// 会员管理
Route::rule('membersList','admin/member/membersList');
Route::rule('memberList1','admin/member/memberList1');
Route::rule('membersAdd','admin/member/membersAdd');
Route::rule('membersEdit','admin/member/membersEdit');
Route::rule('membersPassword','admin/member/membersPassword');
Route::rule('membersDel','admin/member/membersDel');

// 商家管理
Route::rule('businesList','admin/busines/businesList');
Route::rule('businesAdd','admin/busines/businesAdd');
Route::rule('businesEdit','admin/busines/businesEdit');
Route::rule('businesShow','admin/busines/businesShow');
Route::rule('businesActive','admin/busines/businesActive');
Route::rule('businesDel','admin/busines/businesDel');

// 商品库管理
Route::rule('commodityCategoryList','admin/commodity/commodityCategoryList');
Route::rule('commodityCategoryAdd','admin/commodity/commodityCategoryAdd');
Route::rule('commodityCategoryEdit','admin/commodity/commodityCategoryEdit');
Route::rule('commodityCategoryDel','admin/commodity/commodityCategoryDel');
Route::rule('commodityList','admin/commodity/commodityList');
Route::rule('commodityAdd','admin/commodity/commodityAdd');
Route::rule('commodityEdit','admin/commodity/commodityEdit');
Route::rule('commodityDel','admin/commodity/commodityDel');
Route::rule('commodityActive','admin/commodity/commodityActive');

// 名片管理
Route::rule('cardsList','admin/card/cardsList');
Route::rule('cardsAdd','admin/card/cardsAdd');
Route::rule('cardsEdit','admin/card/cardsEdit');
Route::rule('cardsDel','admin/card/cardsDel');
Route::rule('cardsActive','admin/card/cardsActive');

// 公告管理
Route::rule('noticesList','admin/notice/noticesList');
Route::rule('noticesAdd','admin/notice/noticesAdd');
Route::rule('noticesEdit','admin/notice/noticesEdit');
Route::rule('noticesDel','admin/notice/noticesDel');
Route::rule('noticesActive','admin/notice/noticesActive');

// 订单管理
Route::rule('ordersList','admin/order/ordersList');
Route::rule('ordersAdd','admin/order/ordersAdd');
Route::rule('ordersEdit','admin/order/ordersEdit');
Route::rule('orderDel','admin/order/orderDel');

// 广告位管理
Route::rule('pictureAdd','admin/picture/pictureAdd');
Route::rule('pictureEdit','admin/picture/pictureEdit');
Route::rule('pictureList','admin/picture/pictureList');
Route::rule('pictureDel','admin/picture/pictureDel');
Route::rule('pictureShow','admin/picture/pictureShow');
Route::rule('pictureActive','admin/picture/pictureActive');
Route::rule('download','admin/picture/download');

// 优惠管理
Route::rule('discountList','admin/discount/discountList');
Route::rule('discountAdd','admin/discount/discountAdd');
Route::rule('discountEdit','admin/discount/discountEdit');
Route::rule('discountDel','admin/discount/discountDel');

// 收货地址管理
Route::rule('addresList','admin/address/addresList');
Route::rule('addresDel','admin/address/addresDel');

// 配送管理
Route::rule('deliveryList','admin/delivery/deliveryList');
Route::rule('deliveryAdd','admin/delivery/deliveryAdd');
Route::rule('deliveryEdit','admin/delivery/deliveryEdit');
Route::rule('deliveryDel','admin/delivery/deliveryDel');

// 便民电话管理
Route::rule('telephonesList','admin/telephone/telephonesList');
Route::rule('telephonesAdd','admin/telephone/telephonesAdd');
Route::rule('telephonesEdit','admin/telephone/telephonesEdit');
Route::rule('telephonesDel','admin/telephone/telephonesDel');

// 钱包管理
Route::rule('walletsList','admin/wallets/walletsList');
Route::rule('walletsEdit','admin/wallets/walletsEdit');
Route::rule('walletsDel','admin/wallets/walletsDel');



Route::rule('group','admin/Querys/group');

//Route::rule('QueryList','index/QueryList/index');




// *************** index页面路由 *************** //

// 用户注册
Route::rule('register','index/register/register');

// 登录
Route::rule('login','index/login/login');
Route::rule('logout','index/login/logout');

// 名片
Route::rule('cardList','index/card/cardList');
Route::rule('cardAdd','index/card/cardAdd');
Route::rule('cardEdit','index/card/cardEdit');
Route::rule('cardDel','index/card/cardDel');
Route::rule('cardDetails','index/card/cardDetails');
Route::rule('cardPurchase','index/card/cardPurchase');

// 便民电话
Route::rule('telephoneList','index/telephone/telephoneList');
Route::rule('telephoneAdd','index/telephone/telephoneAdd');
Route::rule('telephoneEdit','index/telephone/telephoneEdit');

// 广告图
Route::rule('picList','index/picture/picList');

// 公告
Route::rule('noticeList','index/notice/noticeList');

// 商家管理
Route::rule('businessList','index/business/businessList');
Route::rule('businessAdd','index/business/businessAdd');

// 用户管理
Route::rule('userList','index/user/userList');
Route::rule('userEdit','index/user/userEdit');

// 地址管理
Route::rule('addressList','index/address/addressList');
Route::rule('addressAdd','index/address/addressAdd');
Route::rule('addressEdit','index/address/addressEdit');
Route::rule('addressDel','index/address/addressDel');


return [
    '__pattern__' => [
        'name' => '\w+',
    ],
    '[hello]'     => [
        ':id'   => ['index/hello', ['method' => 'get'], ['id' => '\d+']],
        ':name' => ['index/hello', ['method' => 'post']],
    ],

];
